<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%
	String appPath = request.getContextPath();
%>
<div>
	<div class="mainlist2" id="goods_list">
		<c:if test="${pageResult.totalElements==0}">
			<div style="text-align: center;vertical-align:middle; line-height:120px ;width: 100%;min-height: 120px;font-size: 16px; ">
			<input type="hidden" value="1" id="emptyListFlag" />
			抱歉，没有找到符合条件的商品
			</div>
		</c:if>
		  <c:forEach items="${pageResult.content}" var="goods">
	         <div class="mainlist3">
	           <div class="mainlist31"><a href="<%=appPath%>/goods/${goods.id}.htm" target="_blank"><img src="${goods.image}" /></a></div>
	           <div class="mainlist32">
	             <ul>
	               <li><a href="<%=appPath%>/goods/${goods.id}.htm" target="_blank">${goods.name}</a></li>
	               <li>
						<c:choose>
							<c:when test="${goods.points!=null&&goods.points!=0}">
								<h3>${goods.points}积分</h3>
							</c:when>
							<c:otherwise>
			               		<h3>￥<fmt:formatNumber value="${goods.price/100}" pattern="0.00"/></h3>
							</c:otherwise>
						</c:choose>	               		
	               		<p>销量：${goods.salenum}</p>
	               	</li>
	             </ul>
	           </div>
	         </div>
	       </c:forEach>
	       <input type="hidden" id="pageCount" value="${pageResult.totalPages}"/>
	</div>
</div>
